// 获取系统信息
const SYSTEM_INFO = uni.getSystemInfoSync() 
const getstatusBarHeight = ()=> SYSTEM_INFO.statusBarHeight;

// 胶囊按钮高度
const getTitleBarHeight = ()=>{
	if(uni.getMenuButtonBoundingClientRect){
		const {top,height} = uni.getMenuButtonBoundingClientRect()
		return height + (top - getstatusBarHeight())*2
	}
	else {
		return 40;
	}
}

export const getNavBarHeight = () => getstatusBarHeight() + getTitleBarHeight()
export{getstatusBarHeight,getTitleBarHeight}